<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>k60Pro布局</title>
</head>

<body>
    <div class="content">
        <div class="box">
            <div class="box-child a">1</div>
            <div class="box-child b">2</div>
            <div class="box-child c">3</div>
            <div class="box-child d">4</div>
            <div class="box-child e">5</div>
            <div class="box-child f">6</div>
            <div class="box-child g">7</div>
        </div>
    </div>
    <style>
        /*内容区*/
        .content {
            max-width: 500px;
            margin: 0 auto;
            border: 1px solid red;
        }

        .box {
            display: grid;
            grid-template-columns: repeat(4, minmax(100px, 1fr));
            grid-template-rows: repeat(3, minmax(100px, 1fr));
            /*行间距，列间距*/
            grid-gap: 10px;
            /*内容区中容器中居中*/
            justify-content: center;
            /*放置顺序 - 先行后列*/
            /*grid-auto-flow: row dense;*/
        }

        .box-child {
            background-color: #444;
            color: #fff;
            border-radius: 5px;
            /*布局*/
            display: flex;
            /*水平居中*/
            justify-content: center;
            /*垂直居中*/
            align-items: center;


        }

        .a {
            grid-column: 1/3;

        }

        .b {
            grid-column: 3/4;
            grid-row: 1/3;

        }

        .d {
            grid-row: 2/4;

        }

        .e {
            grid-row: 2/4;

        }

        .g {
            grid-column: 3/5;
        }
    </style>
    <!--
    https://www.mi.com/redmi-k60-pro?spmref=mihomepage.mtl_63958f408a1e0e0001c29225.1
    -->
</body>

</html>